@import '../vars.scss';

header {
  .city-select {
    margin-right: auto;
    display: flex;
    position: relative;
    cursor: pointer;
    &:hover {
      & > .current {
        background: white;
        border: solid 1px #999;
        border-top: none;
        border-bottom: #fff;
      }
      & > .city-lists {
        display: grid;
      }
    }
    & > .current {
      display: flex;
      align-items: center;
      padding: 0 10px;
      z-index: 1;
      border: solid 1px transparent;
      i.fa {
        margin-right: 5px;
        color: red;
      }
    }
    & > .city-lists {
      position: absolute;
      border: solid 1px #999;
      padding: 10px;
      display: grid;
      background: #fff;
      top: calc(100% - 1px);
      grid-template: 25px / repeat(5, 50px);
      grid-auto-rows: 25px;
      gap: 15px 10px;
      display: none;
      a {
        text-decoration: none;
        display: grid;
        align-items: center;
        justify-items: center;
        color: $fontColor;
        font-size: 12px;
        &.active {
          background-color: red;
          color: white;
        }
        &:hover:not(.active) {
          background-color: #f3f3f3;
          color: red;
        }
      }
    }
  }
}
